<section class="content-header">
  <h1>
    <%= t('.title') %>
    <small>it all starts here</small>
  </h1>
  <ol class="breadcrumb">
    <li><a href="#"><i class="fa fa-dashboard"></i> Home</a></li>
    <li><a href="#">Examples</a></li>
    <li class="active">Blank page</li>
  </ol>
</section>

<!-- Main content -->
<section class="content">

  <!-- Default box -->
  <div class="box">
    <div class="box-header">
      <h3 class="box-title">OAuth</h3>

      <div class="box-tools pull-right">
        <a class="label label-success" href="<%= new_oauth_application_path %>">
          <i class="fa fa-plus"></i>
          添加应用
        </a>
      </div>
      <!-- /.box-tools -->
    </div>
    <div class="box-body">
      <%= grid(@applications, show_filters: :when_filtered) do |g|
        g.column name: "#{t '.name'}", attribute: 'name' do |c|
          link_to c.name, oauth_application_path(c)
        end
        g.column name: "#{t '.callback_url'}", attribute: 'redirect_uri'
        g.column do |c|
          opts = link_to t('doorkeeper.applications.buttons.edit'), edit_oauth_application_path(c), class: 'btn bg-olive btn-xs'
          opts += render 'delete_form', application: c
          opts.html_safe
        end
      end %>
    </div>
  </div>
  <!-- /.box -->

</section>